{
  "version": 5,
  "cmakeMinimumRequired": {
    "major": 3,
    "minor": 23,
    "patch": 0
  },
  "configurePresets": [
    {
      "name": "ninja-multi",
      "displayName": "Ninja Multi-Config",
      "description": "build using Ninja generator",
      "generator": "Ninja Multi-Config",
      "binaryDir": "${sourceDir}/build/ninja-multi",
      "cacheVariables": {
        "CMAKE_EXPORT_COMPILE_COMMANDS": {
          "type": "BOOL",
          "value": "ON"
        },
        "CMAKE_CONFIGURATION_TYPES": {
          "type": "STRING",
          "value": "Debug;Release;RelWithDebInfo;MinSizeRel"
        }
      }
    },
    {
      "name": "ninja",
      "displayName": "Ninja",
      "description": "build using Ninja generator",
      "generator": "Ninja",
      "binaryDir": "${sourceDir}/build/ninja",
      "cacheVariables": {
        "CMAKE_EXPORT_COMPILE_COMMANDS": {
          "type": "BOOL",
          "value": "ON"
        },
        "CMAKE_BUILD_TYPE": {
          "type": "STRING",
          "value": "Debug"
        }
      }
    },
    {
      "name": "ninja-llvm",
      "inherits": "ninja",
      "displayName": "Ninja-llvm",
      "description": "build using Ninja generator",
      "generator": "Ninja",
      "binaryDir": "${sourceDir}/build/ninja-llvm",
      "cacheVariables": {
        "CMAKE_CXX_COMPILER": {
          "type": "INTERNAL",
          "value": "clang++"
        },
        "CMAKE_CXX_FLAGS": {
          "type": "STRING",
          "value": "-stdlib=libc++"
        },
        "CMAKE_C_COMPILER": {
          "type": "INTERNAL",
          "value": "clang"
        }
      }
    },

    {
      "name": "xcode",
      "displayName": "xcode",
      "description": "build using Xcode generator",
      "generator": "Xcode",
      "binaryDir": "${sourceDir}/build/xcode",
      "cacheVariables": {
        "CMAKE_EXPORT_COMPILE_COMMANDS": {
          "type": "BOOL",
          "value": "ON"
        }
      },
      "condition": {
        "type": "equals",
        "lhs": "${hostSystemName}",
        "rhs": "Darwin"
      }
    },
    {
      "name": "vs2022",
      "inherits": "ninja",
      "generator": "Visual Studio 17 2022",
      "displayName": "Visual Studio 17 2022",
      "description": "build using Visual Studio 17 2022 generator",
      "binaryDir": "${sourceDir}/build/vs2022",
      "condition": {
        "type": "equals",
        "lhs": "${hostSystemName}",
        "rhs": "Windows"
      }
    },
    {
      "name": "vs2019",
      "inherits": "vs2022",
      "displayName": "Visual Studio 16 2019",
      "description": "This build Visual Studio 16 2019 on Windows",
      "generator": "Visual Studio 16 2019",
      "binaryDir": "${sourceDir}/build/vs2019",
      "condition": {
        "type": "equals",
        "lhs": "${hostSystemName}",
        "rhs": "Windows"
      }
    },
    {
      "name": "mingw",
      "inherits": "ninja",
      "displayName": "MinGW Makefiles",
      "binaryDir": "${sourceDir}/build/mingw",
      "description": "This build MinGW Makefiles on Windows",
      "generator": "MinGW Makefiles"
    }
  ],
  "buildPresets": [
    {
      "name": "ninja",
      "configurePreset": "ninja"
    },
    {
      "name": "ninja-multi",
      "configurePreset": "ninja-multi"
    },
    {
      "name": "ninja-llvm",
      "configurePreset": "ninja-llvm"
    },
    {
      "name": "xcode",
      "configurePreset": "xcode"
    }
  ],
  "testPresets": [
    {
      "name": "ninja",
      "configurePreset": "ninja",
      "output": {"outputOnFailure": true},
      "execution": {"noTestsAction": "error", "stopOnFailure": true}
    }
  ]
}
